<template>
	<div class="header">
		<span @click="toggle">
			<el-icon-expand v-if="!isCollapse"></el-icon-expand>
			<el-icon-fold v-else></el-icon-fold>
		</span>
		<span>基于element-plus二次封装组件库 by lix_uan</span>
	</div>
</template>

<script lang="ts" setup>
	let props = defineProps < {
		isCollapse: boolean
	} > ()
	let emits = defineEmits(['update:isCollapse'])

	let toggle = () => {
		emits('update:isCollapse', !props.isCollapse)
	}
</script>

<style lang="scss" scoped>
	.header {
		height: 60px;
		padding: 0 20px;
		display: flex;
		align-items: center;
		justify-content: space-between;
	}
</style>
